package com.talent.service.iot.mqtt.service;

import com.talent.service.iot.mqtt.model.request.TlMqttPubRecReq;
import com.talent.service.iot.mqtt.model.request.TlMqttPubRelReq;
import com.talent.service.iot.mqtt.model.request.TlMqttPublishReq;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;

/**
 * @ClassName：IMqttMsgService
 * @Author: hszhou
 * @Date: 2025/1/7 9:33
 * @Description: 必须描述类做什么事情, 实现什么功能
 */
public interface IMqttMsgService {


    Mono<Void> savePublishMessage(String clientId, int messageId, TlMqttPublishReq req);

    Mono<Void> clearPublishMessage(String clientId,int messageId);

    Mono<Void> clearPublishMessage(String clientId);

    Mono<TlMqttPublishReq> findPublishMessage(String clientId, int messageId);

    Flux<TlMqttPublishReq> findPublishMessage(String clientId);

    Mono<Void> savePubRelMessage(String clientId,int messageId, TlMqttPubRelReq req);

    Mono<Void> clearPubRelMessage(String clientId,int messageId);

    Mono<Void> clearPubRelMessage(String clientId);

    Mono<TlMqttPubRelReq> findPubRelMessage(String clientId,int messageId);

    Flux<TlMqttPubRelReq> findPubRelMessage(String clientId);

    Integer getMessageId();


    Mono<Void> savePubRecMessage(String clientId,int messageId, TlMqttPubRecReq req);

    Mono<Void> clearPubRecMessage(String clientId,int messageId);
}
